console.log(self);

function add(nums) {
  let total = 0;
  for (let key = 0; key < nums; key++) {
    total += key;
  }
  return total;
}

const num = add(10000000000);

console.log(num);

self.postMessage(num);


